﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using System.IO;
using GeneralTools;

namespace MtgPrinter
{
    [Serializable]
    public class MtgPrinterConfiguration :ApplicationConfiguration
    {
        public decimal CardWidthCM { get; set; }
        public decimal CardHeightCM { get; set; }
        public decimal CardAspectRatio { get; set; }
        public bool CardMaintainRatio { get; set; }
        public int NumberOfDownloadingThreads { get; set; }
        public bool AllowDiskCaching { get; set; }
        public long MaxCacheSize { get; set; }
        public int RemoveFromCacheAfter { get; set; }
        public MtgLib.EDownloadPicturesFrom DownloadPicturesFrom;
        public EExportPdfPageSize PdfPageSize;

        public MtgPrinterConfiguration()
        {
            CardMaintainRatio = true;
            CardAspectRatio = 0.701m;
            CardWidthCM = 6.3m;
            CardHeightCM = 8.8m;
            NumberOfDownloadingThreads = 4;

            DownloadPicturesFrom = MtgLib.EDownloadPicturesFrom.MagicCards_info;
            PdfPageSize = EExportPdfPageSize.A4;

            AllowDiskCaching = true;
            MaxCacheSize = 0;
            RemoveFromCacheAfter = 10;
        }
    }
}
